﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Net;
using System.Net.Http;
using System.Text;

namespace XCrawler
{
    /// <summary>
    /// 响应流的信息
    /// </summary>
    public class ResponseStreamInfo
    {
        public ResponseStreamInfo(HttpResponseMessage response, Stream stream, long contentLength)
        {
            this.Response = response;
            this.StatusCode = response.StatusCode;
            this.Stream = stream;
            this.ContentLength = contentLength;
        }

        /// <summary>
        /// 返回相应
        /// </summary>
        public HttpResponseMessage Response { get; set; }
        /// <summary>
        /// 流
        /// </summary>
        public Stream Stream { get; set; }
        /// <summary>
        /// 内容大小
        /// </summary>
        public long ContentLength { get; set; }

        /// <summary>
        /// 请求状态
        /// </summary>
        public HttpStatusCode StatusCode { get; set; }

    }
}
